import request from '@/utils/request'

export function createExportJob(module: 'material' | 'warehouse', params: any) {
  return request({ url: '/erp/export/job', method: 'post', params: { module }, data: params })
}

export function getExportJobStatus(jobId: string | number) {
  return request({ url: `/erp/export/job/${jobId}/status`, method: 'get' })
}

export function downloadExportJob(jobId: string | number) {
  return request({ url: `/erp/export/job/${jobId}/download`, method: 'get', responseType: 'blob' })
}


